Skip to content

Use render-engine's init instead of cookiecutter - #75

Merged
brass75 merged 3 commits into
render-engine:mainfrom
tystar86:issue-45-use-render-engine-init
Dec 3, 2026
Merged

brass75 merged 3 commits into
render-engine:mainfrom
tystar86:issue-45-use-render-engine-init

Conversation

@tystar86

Copy link
Copy Markdown
Contributor

render-engine initnow passes its arguments torender_engine.init` (added in render-engine/render-engine#1353), which creates the site from templates maintained in render-engine. This removes the dependency on the separate cookiecutter template, so changes to new sites only need to be made in one place.

Closes #45

  • The init command forwards all its arguments to render_engine.init.__main__.main(args, prog="render-engine init"), so its options, questions and help come from render-engine.
  • Custom templates (--template) and cookiecutter config files (--config-file) are no longer supported, as agreed with @brass75. render-engine init --help says so.
  • cookiecutter is removed from the dependencies.
  • The cookiecutter tests are replaced with tests for the new init: it's listed in the help, it passes the arguments, it shows init's help, it creates a site, and it rejects --template.
  • The README has a short "Create a New Site" section.
  • uv lock also synced prek and ruff to the versions already pinned in pyproject.toml.

Contributing guidelines

  • I have read and abided by all of the contributing guidelines for this project.
  • The issue this PR resolves has been assigned to me.

Type of Issue

  • 🐛 (bug)
  • 📖 (Documentation)
  • ⬆️ (Update)
  • 💫 (New Feature)
  • ☢️ (Deprecation)
  • 🚫 (Removal)
  • 🛠️ (Refactor)

Changes have been Documented (If Applicable)

  • YES - Changes have been documented

Changes have been Tested

  • YES - Changes have been tested

Next Steps

  • CI will fail until render-engine is released with render_engine.init. The latest release on PyPI (2026.9.1) doesn't include it yet. I tested locally with render-engine main installed in the environment.
  • After the release, raise the minimum render-engine version in pyproject.toml to that release.

AI Attestation

I used Claude Code (Claude Opus 5.5) to explain the code and concepts, review my changes, and draft the tests and this description. I wrote and tested the code myself.

render-engine init now passes its arguments to render_engine.init, which creates the site from templates in render-engine. Custom templates (--template) and cookiecutter config files (--config-file) are no longer supported, and cookiecutter is removed from the dependencies. The README shows how to create a new site. uv lock also synced prek and ruff to the versions already pinned in pyproject.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

Contributor profile

(This comment and the linked profile output will auto-delete when this PR is closed.)

render-engine 2026.11.1a3 includes render_engine.init. It pins its own dependencies, so uv lock updates them too. The collection entry tests now each use their own tmp_path, because render-engine no longer overwrites an existing entry file.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Comment thread src/render_engine_cli/cli.py Resolved
Comment thread tests/test_cli.py Resolved
Comment thread tests/test_render_engine_init.py Resolved
argparse accepts any sequence, so the arguments from click are passed on without converting them to a list. The test keeps the arguments in one variable that is both passed and checked.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@tystar86
tystar86 requested a review from brass75 December 3, 2026 09:08
@brass75
brass75 merged commit 0ed13f4 into render-engine:main Dec 3, 2026
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Refactor render-engine init to use internal code and templates and deprecate the cookiecutter.

2 participants